import svgIconPlugin from './svg-icon.ts'
import autoImportPlugin from './auto-import.ts'
import htmlPlugin from './html.ts'
import iconsPlugin from './icons.ts'
import vueComponentsPlugin from './vue-components.ts'

export default function initVitePlugin() {
  const isBuild = process.env.NODE_ENV === 'production'
  const vitePlugins = []
  vitePlugins.push(svgIconPlugin(isBuild))
  vitePlugins.push(autoImportPlugin())
  vitePlugins.push(htmlPlugin(isBuild))
  vitePlugins.push(iconsPlugin())
  vitePlugins.push(vueComponentsPlugin())
  return vitePlugins
}
